package i_oStream.charStream;

import java.io.FileReader;
import java.io.IOException;

public class CharFileReader {
    public static void main(String[] args) throws IOException {
        FileReader reader = new FileReader("D:\\develop\\程序\\JAVAFourDimension-master\\JAVAFourDimension\\src\\I_O\\charStream\\xuruiqi.txt");
        //无参
        /*int num;
        while ((num=reader.read())!=-1){
            System.out.print((char) num);
        }*/
        //有参
        char[] chars = new char[10];
        int num01;
        while ((num01 = reader.read(chars)) != -1) {
            System.out.print(new String(chars, 0, num01));
        }
        reader.close();
    }
}
